TrueForAll Generic Method

Wintellect PowerCollections

Collapse imageExpand ImageCollapseAll imageExpandAll imageDropDown imageDropDownHover imageCopy imageCopyHover image
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Determines if all of the items in the collection satisfy the condition defined by predicate.

Namespace: Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax

C#
public static bool TrueForAll<T>(
	IEnumerable<T> collection,
	Predicate<T> predicate
)
Visual Basic (Declaration)
Public Shared Function TrueForAll(Of T) ( _
	collection As IEnumerable(Of T), _
	predicate As Predicate(Of T) _
) As Boolean
Visual C++
public:
generic<typename T>
static bool TrueForAll (
	IEnumerable<T>^ collection, 
	Predicate<T>^ predicate
)

Parameters

collection
IEnumerable<(Of <T>)>
The collection to check all the items in.
predicate
Predicate<(Of <T>)>
A delegate that defines the condition to check for.

Return Value

True if all of the items in the collection satisfy the condition defined by predicate, or if the collection is empty. False if one or more items in the collection do not satisfy predicate.

Type Parameters

T

See Also